package com.sc.nft.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.sc.nft.entity.DaoSchoolChild;
import com.sc.nft.entity.dto.DaoSchoolChildPageAdminDTO;
import com.sc.nft.entity.dto.DaoSchoolChildTopGetListAllDTO;
import com.sc.nft.entity.vo.DaoSchoolArticleMaterialTopIdVO;
import com.sc.nft.entity.vo.DaoSchoolChildPageAdminVO;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * dao学堂子分类表(DaoSchoolChild)表数据库访问层
 *
 * @author makejava
 * @since 2023-03-13 16:21:51
 */
public interface DaoSchoolChildMapper extends BaseMapper<DaoSchoolChild> {

    /**
     * 分页获取1级分类列表
     *
     * @param page
     * @return
     */
    Page<DaoSchoolChildPageAdminVO> pageAdmin(Page page, @Param("data") DaoSchoolChildPageAdminDTO dto);

    /**
     * 根据父集ID获取子集列表
     *
     * @param id
     * @return
     */
    List<DaoSchoolChildPageAdminVO> selectByTopIdsGetListAll(@Param("data") DaoSchoolChildTopGetListAllDTO daoSchoolChildTopGetListAllDTO);

    /**
     * 根据父集id,获取子集列表
     *
     * @param topId
     * @return
     */
    List<DaoSchoolArticleMaterialTopIdVO> selectByTopId(@Param("topId") Long topId, @Param("daoId") Long daoId);

}
